home *** CD-ROM | disk | FTP | other *** search
/ Nebula 2 / Nebula Two.iso / SourceCode / MiscKit1.7.1 / MiscKit / Headers / misckit / MiscDirectory.h < prev    next >
Encoding:
Text File  |  1994-12-10  |  1.4 KB  |  54 lines

  1. //
  2. //    MiscDirectory -- <one or two line summary>
  3. //        Written by Simson L. Garfinkel <simsong@pleasant.cambridge.ma.us>
  4. //    Extended and maintained by Georg Tuparev <tuparev@embl-heidelberg.de>
  5. //    Copyright 1994 by Simson L. Garfinkel.
  6. //                Version 0.5 beta.  All rights reserved.
  7. //        Last update: 11.12.1994.
  8. //
  9. //        This notice may not be removed from this source code.
  10. //
  11. //    This object is included in the MiscKit by permission from the author
  12. //    and its use is governed by the MiscKit license, found in the file
  13. //    "License.rtf" in the MiscKit distribution.  Please refer to that file
  14. //    for a list of all applicable permissions and restrictions.
  15. //    
  16.  
  17. #import <appkit/appkit.h>
  18. #import <sys/dir.h>
  19.  
  20. @interface MiscDirectory:Object
  21. {
  22.     List *fileNameList;
  23.     int currentEntry;
  24.     char    *dirName;
  25.     char    *filetype;        /* only return this file type */
  26. }
  27.  
  28. + initialize;
  29.  
  30. /* initialization and freeing */
  31. - initForDirectory:(const char *)dirname;
  32. - free;
  33. - setFileType:(const char *)filetype;
  34. - sortDir;
  35.  
  36. /* information about current entry */
  37. - (const char *)entry;
  38. - (const char *)fullPathName;
  39. - (const char *)extension;        /* return "" if no extension */
  40.  
  41.  
  42. /* movement */
  43. - (const char *)nextEntry;        /* move to next entry */
  44. - rewind;
  45.  
  46. /* information about directory */
  47. - (int)matchingEntries;
  48.  
  49. /* Archiving */
  50. - read:(NXTypedStream *)stream;
  51. - write:(NXTypedStream *)stream;
  52.  
  53. @end
  54.